The present invention relates to the field of simulations. More particularly, the present invention relates to harmonic balance simulations.
Simulations are used to model physical devices to facilitate device design, prototyping, and/or testing. A computer system typically runs simulations by executing a set of instructions or code representative of devices and the functionalities/interactions that occur between these devices. A modeled device may comprise a component on an integrated chip (e.g., a resistor, transistor, processor, bus, clock memory, etc.), the entire integrated circuit (I C), a system including an IC, or other components of an electronic system.
Once a model representative of a device has been generated, various properties of the device, including its interaction with other modeled device(s), can be analyzed within the simulation environment. The collection of one or more modeled devices (also referred to as a modeled system) is analyzed by subjecting it to various known inputs and studying the outputs. Given the complexity of devices represented by the modeled system, a number of different analyses are typically performed to fully understand device properties and behaviors.
One of the analyses performed on modeled systems is harmonic balance analysis. Harmonic balance analysis comprises a frequency domain analysis technique to obtain the steady state response of a modeled system. A known periodic excitation or signal is provided as the input to the modeled system, such as a radio frequency (RF) or microwave circuit. In response, the modeled system output varies as a function of time—initially, the output is a transient response and then after a long time period, the output stabilizes and becomes periodic. Since the response of interest is the periodic or steady state portion of the output, knowing the point at which the response switches from transient to steady state would be useful. Once the modeled system response has switched from transient to steady state, all harmonics of the steady state response need not be modeled to obtain an accurate steady state response of the modeled system. Instead, merely a certain number of harmonics of the steady state response may be simulated, such simulation result representing an accurate steady state response of the modeled system. The minimum number of harmonics that should be simulated to obtain an accurate steady state response is referred to as an optimal harmonic number for the modeled system.
Currently, when harmonic balance analysis is to be performed on a modeled system, its optimal harmonic number is not known. A user requesting the simulation (e.g., a circuit designer) typically takes a guess and enters the guessed optimal harmonic number as the harmonic number setting. However, if the entered harmonic number is too small, the simulation result suffers from aliasing error, inaccuracy, and/or lack of convergence. Conversely if the entered harmonic number is too large, the simulation takes a long time and/or the simulation may run out of memory before it completes. Moreover, it may not be obvious from the simulation results that an inappropriate harmonic number was used for the harmonic balance analysis simulation.
Thus, it would be beneficial to automatically determine an optimal harmonic number for a circuit to be modeled. It would be further beneficial for the determined harmonic number to facilitate efficient and accurate harmonic balance analysis simulation of the circuit. It would also be beneficial for automatic determination of the optimal harmonic number to occur quickly, especially relative to the harmonic balance analysis simulation time.